﻿<%@ Page Language="C#" MasterPageFile="~/Admin/Admin.master" AutoEventWireup="true" CodeFile="adm_articleDet_upload.aspx.cs" Inherits="Admin_adm_articleDet_upload" Title="Untitled Page" %>

<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder2" Runat="Server">
<h3>
    <asp:Literal ID='ltrPageTitle' runat="server"></asp:Literal>
</h3>
    <table cellspacing="0" cellpadding="3" border="0">																																	
					<tbody><tr><td class="NavL1" colspan="2">
	<asp:Literal ID='ltrTitle' runat="server"></asp:Literal>				
						<a href="adm_article_add.aspx?ckid=<%=ckid %>&aid=<%=aid %>">
						<img hspace="3" height="12" width="12" border="0" align="absmiddle" alt="Edit Article" src="../images/ico_edit.gif"/></a>&nbsp;&nbsp;
						<asp:Button ID='btnMakeFeatured' runat="server" CssClass="btnGo" 
                            Text='Make Featured' onclick="btnMakeFeatured_Click" />
						
					</td></tr>									 
					</tbody></table>
    <table border="0" cellpadding="0" cellspacing="0" width="95%">
        <tr>
            <td class="padRight" valign="top">
                <input name="ext" type="hidden" value="jpg" />
                <input name="Perfix" type="hidden" 
                    value="hinh-nen-may-tinh-noi-bat-su-sang-trong-va-quy-phai-cung-eseci-2009-" />
                <input name="nof" type="hidden" value="14" />
                <input name="lstImageNo" type="hidden" value="14" />
                <input name="sact" type="hidden" value="" />
                <table border="0" cellpadding="3" cellspacing="0">
                    <tr>
                        <td class="clsTitle" nowrap>
                            Country</td>
                        <td>
                            <asp:DropDownList ID="ddlCountry" runat="server" CssClass="frmSort">
                            </asp:DropDownList>
                            &nbsp;</td>
                    </tr>
                    <tr>
                        <td class="clsTitle" nowrap>
                            Year</td>
                        <td>
                            <asp:DropDownList ID="ddlYear" runat="server" CssClass="frmSort">
                            </asp:DropDownList>
                        </td>
                    </tr>
                    <tr>
                        <td class="clsTitle" nowrap>
                            Season</td>
                        <td>
                            <asp:DropDownList ID="ddlSeason" runat="server" CssClass="frmSort">
                                <asp:ListItem Value="2">Thu - Đông</asp:ListItem>
                                <asp:ListItem Value="1">Xuân - Hè</asp:ListItem>
                            </asp:DropDownList>
                        </td>
                    </tr>
                    <tr>
                        <td class="clsTitle" nowrap>
                            Sex</td>
                        <td>
                            <asp:DropDownList ID="ddlSex" runat="server" CssClass="frmSort">
                              
                                <asp:ListItem Value="1">Nam</asp:ListItem>
                                <asp:ListItem Value="2">Nữ</asp:ListItem>
                            </asp:DropDownList>
                        </td>
                    </tr>
                    <tr>
                        <td class="clsTitle" nowrap>
                            Image Title</td>
                        <td valign="top">
                            <asp:TextBox ID="txtImageTitle" runat="server" CssClass="frmSortM"
                              ></asp:TextBox>
                        </td>
                    </tr>
                    <tr>
                        <td class="clsTitle">
                            Brand</td>
                        <td valign="top">
                            <asp:TextBox ID="txtBrand" runat="server" CssClass="frmSortM"></asp:TextBox>
                        </td>
                    </tr>
                </table>
            </td>
            <td valign="top">
                <table border="0" cellpadding="2" cellspacing="0">
                    <tr>
                        <td class="clsTitle" nowrap valign="top">
                            Wear Type</td>
                        <td>
                            &nbsp;<asp:ListBox ID="lstWearType" runat="server" CssClass="frmSort">
                            </asp:ListBox>
                        </td>
                    </tr>
                    <tr>
                        <td class="clsTitle" nowrap>
                            Oriented Image</td>
                        <td>
                            &nbsp;<asp:DropDownList ID="ddlOrientedImage" runat="server" CssClass="frmSort">
                                <asp:ListItem Value="">Auto detect</asp:ListItem>
                                <asp:ListItem Value="0">Vertical</asp:ListItem>
                                <asp:ListItem Value="1">Horizontal</asp:ListItem>
                            </asp:DropDownList>
                        </td>
                    </tr>
                    <tr>
                        <td class="clsTitle">
                            Image</td>
                        <td>
                            <asp:FileUpload ID="fluImage" runat="server" CssClass="frmSortM" />
                        </td>
                    </tr>
                    <tr>
                        <td>
                                        <asp:Button ID="btnNew" runat="server" CssClass="btnGo" 
                                Text="Add New" onclick="btnNew_Click" />
                                    </td>
                        <td>
                            <table border="0" cellpadding="0" cellspacing="0" width="100%">
                                <tr>
                                    <td>
                                        <asp:Button ID="btnSaveEdit" runat="server" CssClass="btnGo" Text="Update" 
                                            onclick="btnSaveEdit_Click" />
                                    </td>
                                    <td align="right">
                                        &nbsp;&nbsp;&nbsp;
                                        <asp:Button ID="btnMakeMainImage" runat="server" CssClass="btnGo" 
                                            Text="Make Main Image" onclick="btnMakeMainImage_Click" />
                                        &nbsp;</td>
                                </tr>
                            </table>
                        </td>
                    </tr>
                </table>
            </td>
        </tr>
    </table>
    <br />
        <asp:DataList ID="dtlImage" runat="server" RepeatColumns="4" 
        onitemcommand="dtlImage_ItemCommand" RepeatDirection="Horizontal" 
        Width="100%">
            <ItemTemplate>
                <asp:TextBox ID="txtNameImage" runat="server" Text='<%# DetailImageName(Eval("ID"), Eval("kTitle"), Eval("fYear"), Eval("ImageNo")) %>'></asp:TextBox><br />
                <asp:ImageButton ID="btnDelete" runat="server" OnClientClick="return confirm('Do you want to DELETE?')" 
                ImageUrl="~/images/ico_delete.gif" onclick="btnDelete_Click"
                 CommandArgument='<%# Eval("IID") %>' CommandName="Delete" />
                 <a href='?ckid=<%=ckid %>&aid=<%=aid %>&iid=<%# Eval("IID") %>&imgName=<%# DetailImageName(Eval("ID"), Eval("kTitle"), Eval("fYear"), Eval("ImageNo")) %>'>
                <asp:Image ID="btnEdit" runat="server"                                
                ImageUrl="~/images/ico_edit.gif"  />
                </a>
                <asp:RadioButton ID="rdbSelect" runat="server" GroupName="SelectAnImage" />
                <asp:Literal ID="ltrImageID" runat="server" Visible="false"
                  Text='<%# Eval("IID") %>'   ></asp:Literal>
                  <br />
                <img alt='<%# Eval("kTitle")  %>' 
                src='../<%# DetailImage(Eval("ID"), Eval("kTitle"), Eval("fYear"), Eval("ImageNo"))%>' 
                style="width:120px; height:auto;" />
            </ItemTemplate>
        </asp:DataList>
    <br />
</asp:Content>

